<#include "macrosDisplay.ftl">
<#include "macrosLoops.ftl">
<#include "macroUtils.ftl">
<#include "tpsTypes.ftl">
<#-- bo == an enumeration in this template -->
package com.tps.gen.bo;

/**
 * <p>
 * An enumeration of <@cap bo.name />(s).
 * </p>
 *
 * <p>${bo.description}</p>
 * 
 * <p>Created ${util.getDateString()}</p>
 * 
 * @author Archimedes
 * @version $Id: Enumeration.ftl 2052 2006-03-06 22:14:26 +0000 (Mon, 06 Mar 2006) erik $
 */
public enum <@cap bo.name /> {

	<#list bo.values as value>${value.name}("${value.displayName?default("")}")<#if value_has_next>,</#if></#list>;

    private String displayName;

    <@cap bo.name />(String _displayName) {
        displayName = _displayName;
    }
    
    /**
     * Returns a String value of the displayName if its is not null or not a empty-string. Otherwise,
     * returns the name of the constant.
     */
    public String getDisplayName() {
    	if (displayName != null && (displayName.equals("") == false)) {
    		return displayName;
    	}
    	
    	return super.toString();
    }
}
